<?php
session_start();
if(!$_SESSION["trv3_07"]){
	header("location:../login.php");
	exit;
}
require "../resources/v1.php";
if( !get_magic_quotes_gpc()){
	isset( $_GET['val']) ? $XCD01 = addslashes(trim( $_GET['val'])) : $XCD01 = '';
}else{
	isset( $_GET['val']) ? $XCD01 = trim( $_GET['val']) : $XCD01 = '';
}
if( $XCD01 != ''){
	$conexion = server_reconnect();
	$query = "select v.`id`,v.`mar`,v.`tv`,v.`cha`,v.`mot` from `veh` v where v.`dom`='".$XCD01."'";
	$result = mysql_query( $query, $conexion);
	echo '<?xml version="1.0" encoding="UTF-8"?><input>';
	if( $mxcel = @mysql_fetch_array($result)){
		echo '<CD02>'.$mxcel['mar'].'</CD02>';
		echo '<CD03>'.$mxcel['tv'].'</CD03>';
		echo '<CD04>'.$mxcel['cha'].'</CD04>';
		echo '<CD05>'.$mxcel['mot'].'</CD05>';
		echo '<HD11>'.$mxcel['id'].'</HD11></input>';
	}else{
		echo '<CD02> </CD02><CD03>0</CD03><CD04> </CD04><CD05> </CD05><HD11>0</HD11></input>';
	}
	server_disconnect( $conexion);
}
?>